# -*- coding: utf-8 -*-
# @Author：fanmingxiang@touty.io
# @Date  ：2022/3/2 14:54
import page
from base.base import Base


class PageSearch(Base):

    def __init__(self, driver):
        self.driver = driver

    def page_click_search(self):
        self.base_click(page.search_box)

    def page_input_search(self, search):
        self.base_input(page.search_input, search)

    def page_click_official_account(self):
        self.base_click(page.official_account)

    def page_click_first_menu(self):
        self.base_click(page.first_menu)

    def page_click_second_menu(self):
        self.base_click(page.second_menu)

    def page_webview(self):
        self.base_webview()

    def page_search(self, search):
        self.page_click_search()
        self.page_input_search(search)
        self.page_click_official_account()
        self.page_click_first_menu()
        self.page_click_second_menu()
        self.page_webview()